<html lang="en">
    <head>
        <title>jsinfo</title>
    </head>

    <style>
        .title {
            text-align: center;
            font-size: 2em;
            margin-top: 7%;
            margin-bottom: 2%;
        }
        span {
            display: block;
            text-align: center;
        }
    </style>

    <body>
        <div class="title">jsinfoPage</div>
    </body>


    <script language="javascript" type="text/javascript">
        var loc = location.href;
        console.log(loc)
        var n1 = loc.length;//地址的总长度
        var n2 = loc.indexOf("=");//取得=号的位置
        var id = decodeURI(loc.substr(n2+1, n1-n2));//从=号后面的内容
        // alert(id); 
        document.write(
            "<span> value: " ,id, "</span>"
        );
        </script>
</html>